package cn.huiyunche.base.service.enums;

/**
 * 订单费用类型（下单价格、回单价格）
 * The enum D waybill fee detail cost type.
 */
public enum DWaybillFeeDetailCostTypeEnum {

    /**
     * Create cost d waybill fee detail cost type.
     */
    CREATE_COST(0, "下单价格"),
    /**
     * Return cost d waybill fee detail cost type.
     */
    RETURN_COST(1, "更新价格"),

    /**
     * 重新计算价格
     */
    RECLAC_COST(2, "重新计算");


    private final int value;
    private final String text;

    DWaybillFeeDetailCostTypeEnum(int value, String text) {
        this.value = value;
        this.text = text;
    }

    /**
     * Gets value.
     *
     * @return the value
     */
    public int getValue() {
        return value;
    }

    /**
     * Gets text.
     *
     * @return the text
     */
    public String getText() {
        return text;
    }

    /**
     * Get by value d waybill fee detail cost type.
     *
     * @param value the value
     * @return the d waybill fee detail cost type
     */
    public static DWaybillFeeDetailCostTypeEnum getByValue(int value) {
        for (DWaybillFeeDetailCostTypeEnum temp : DWaybillFeeDetailCostTypeEnum.values()) {
            if (temp.getValue() == value) {
                return temp;
            }
        }
        return null;
    }
}
